package com.yuexunit.finance.project.entity.lexicon;

/**
 * @author wenwenlong
 */
public enum FinanceConstractStateEnum {

	UNKNOWN("合同未上传"), CONSTRACT_UPLOAD("合同已上传"), CONTRACT_SUBMITED("合同已提交"), WAIT_ENTERPRISE_SIGN("待客户签署"),ENTERPRISE_SUBMIT("客户已提交"),WAIT_PLATFORM_SIGN("待平台签署"),PLATFORM_SIGNED("平台已经签署"),CALL_BACK_ALL("全部打回"),WAIT_CONFIRM("待确认"),CALL_BACK("合同已打回");

	private final String paramType;

	private FinanceConstractStateEnum(String paramType) {
		this.paramType = paramType;
	}

	public String getValue() {
		return paramType;
	}

	/**
	 * 数字转为枚举类型
	 * @param value 0:合同未上传/1:合同已上传/2:合同已提交/3:待客户签署/4:客户已提交/5:待平台签署/6:平台已经签署/7:合同已打回/8:待确认/9:全部打回
	 * @return 参数类型枚举
	 */
	public static FinanceConstractStateEnum valueOf(Integer value) {
		if (value == null || values().length <= value.intValue()) {
			return UNKNOWN;
		}
		return values()[value.intValue()];
	}
	
	public static void main(String[] args) {
		for (FinanceConstractStateEnum f : values()) {
			System.out.print(f.ordinal() + ":" + f.getValue() + "/");
		}
	}
}
